#!/usr/bin/env python
# coding=utf-8
# __author__ = 'Yunchao Ling'

infile1=open("D:/data/mesh2/desc2015Result.txt","r")
infile2=open("D:/data/mesh2/desc2014Result.txt","r")

ht={}
for line in infile1:
    line=line.rstrip()
    splitline=line.split("\t")
    id=splitline[0]
    name=splitline[1]
    ht[name]=id
infile1.close()

for line in infile2:
    line=line.rstrip()
    splitline=line.split("\t")
    id=splitline[0]
    name=splitline[1]
    if not ht.has_key(name):
        print line
    elif ht[name]!=id:
        print line
infile2.close()
